clipboard: Add gdk_clipboard_set()
authorBenjamin Otte <otte@redhat.com>
Tue, 5 Dec 2017 04:16:49 +0000 (05:16 +0100)
committerBenjamin Otte <otte@redhat.com>
Tue, 5 Dec 2017 04:29:03 +0000 (05:29 +0100)
commitdc50e0637ffa8bc7a369d00a5d8e7656d03c3781
tree60fc24cb2d8c24879e58ad8b7460aeb412d5827f
parent4658d7ea5484c7d98c43b8f33483e43995efd8d5
clipboard: Add gdk_clipboard_set()

This API allows specifying a GType and va_args of a value of that type
to set the clipboard contents. This massively simplifies setting weird
object types into the clipboard.
2 example patches included in this patch are the GtkTextBuffer and the
file list in the file chooser.

Using gobject-introspection, this should work without specifying the
type, so that you can literlally say
  clipboard.set ("Hello World")
or
  clipboard.set (pixbuf)
which is why I've also marked all other setters as (skip). They just
exist in C as wrappers for type safety reasons.
docs/reference/gdk/gdk4-sections.txt
gdk/gdkclipboard.c
gdk/gdkclipboard.h
gtk/gtkfilechooserwidget.c
gtk/gtktextbuffer.c